<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:th="http://www.thymeleaf.org">
<head th:replace="~{fragments/header :: header}">
</head>
<body>

<div class="container ">
    <div class="row my-4">
        <div class="col-md-6 " >
            <form  th:action="@{/user/login}" method="post">
                <h2 class="col-md-8">请登录</h2>
                <div class="form-group col-md-8">
                    <label for="username" class="col-form-label">账号</label>
                    <input type="text" class="form-control" id="username" name="username" maxlength="50" placeholder="请输入账号">
                </div>
                <div class="form-group col-md-8">
                    <label for="password" class="col-form-label">密码</label>
                    <input type="password" class="form-control" id="password" name="password" maxlength="30" placeholder="请输入密码" >
                </div>
                <div class="form-group col-md-8">
                    <input  type="checkbox" name="remember-me"> 记住我
                </div>
                <div class="form-group col-md-8">
                    <button type="submit" class=" btn btn-primary">登录</button>
                </div>
                <div class=" col-md-5" th:if="${loginError}">
                    <p class="blog-label-error" th:text="${errorMsg}"></p>
                </div>
            </form>
        </div>
        <div class="col-md-6" style="border: 1px solid red;">
        </div>
    </div><!--row-->
</div> <!-- /container -->


<div th:replace="~{fragments/footer :: footer}">...</div>
</body>
</html>